50d98ab52773f5f1a060a811f9f6ac540d61ac16,jetty-websocket/javax-websocket-server-impl/src/main/java/org/eclipse/jetty/websocket/jsr356/server/AnnotatedServerEndpointConfig.java,AnnotatedServerEndpointConfig,AnnotatedServerEndpointConfig,#Class#ServerEndpoint#ServerEndpointConfig#,53

Before Change


    {
        List<Class<? extends Decoder>> compositeDecoders = new ArrayList<>();
        List<Class<? extends Encoder>> compositeEncoders = new ArrayList<>();
        List<String> compositeSubProtocols = new ArrayList<>();

        Configurator configr = null;

        // Copy from base config
        if (baseConfig != null)
        {
            compositeDecoders.addAll(baseConfig.getDecoders());
            compositeEncoders.addAll(baseConfig.getEncoders());
            compositeSubProtocols.addAll(baseConfig.getSubprotocols());
            configr = baseConfig.getConfigurator();
        }

        // now add from annotations
        compositeDecoders.addAll(Arrays.asList(anno.decoders()));
        compositeEncoders.addAll(Arrays.asList(anno.encoders()));
        compositeSubProtocols.addAll(Arrays.asList(anno.subprotocols()));

        // Create unmodifiable lists
        this.decoders = Collections.unmodifiableList(compositeDecoders);

After Change


        }

        // Sub Protocols (favor provided config over annotation)
        if (baseConfig != null && baseConfig.getSubprotocols() != null && baseConfig.getSubprotocols().size() > 0)
        {
            this.subprotocols = Collections.unmodifiableList(baseConfig.getSubprotocols());
        }
        else
        {
            this.subprotocols = Collections.unmodifiableList(Arrays.asList(anno.subprotocols()));
        }

        // Path (favor provided config over annotation)
        if (baseConfig != null && baseConfig.getPath() != null && baseConfig.getPath().length() > 0)
        {
            this.path = baseConfig.getPath();
        }
        else
        {
            this.path = anno.value();
        }

        // supplied by init lifecycle
        this.extensions = new ArrayList<>();
        // always what is passed in
        this.endpointClass = endpointClass;
        // UserProperties in annotation
        this.userProperties = new HashMap<>();
        if (baseConfig != null && baseConfig.getUserProperties() != null && baseConfig.getUserProperties().size() > 0)
        {
            userProperties.putAll(baseConfig.getUserProperties());
        }